package com.brainhealth.customer.service;

import com.brainhealth.customer.domain.*;
import com.brainhealth.customer.domain.vo.*;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.util.List;

/**
 * 埋点记录Service接口
 * 
 * @author ruoyi
 * @date 2023-07-24
 */
public interface ISysBuriedPointService 
{
    /**
     * 查询埋点记录
     * 
     * @param id 埋点记录主键
     * @return 埋点记录
     */
    public SysBuriedPoint selectSysBuriedPointById(Long id);

    /**
     * 查询埋点记录列表
     * 
     * @param sysBuriedPoint 埋点记录
     * @return 埋点记录集合
     */
    public List<SysBuriedPoint> selectSysBuriedPointList(SysBuriedPoint sysBuriedPoint);

    /**
     * 新增埋点记录
     *
     * @param buriedPointParam 埋点记录
     * @return 结果
     */
    Integer addBuriedPoint(HttpServletRequest request, BuriedPointParam buriedPointParam);

    /**
     * 新增用户事件埋点记录
     * @param request
     * @param userEventBuriedPointParam
     * @return
     */
    int addUserEventBuriedPoint(HttpServletRequest request, UserEventBuriedPointParam userEventBuriedPointParam);

    /**
     * 获取用户在线时长
     * @param userEventBuriedPointQueryParam
     * @return
     */
    UserOnlineTimeVO getUserOnlineTime(UserEventBuriedPointQueryParam userEventBuriedPointQueryParam);

    /**
     * 获取用户在线时长明细
     * @param userEventBuriedPointQueryParam
     * @return
     */
    List<UserOnlineTimeDetail> getUserOnlineTimeDetailList(UserEventBuriedPointQueryParam userEventBuriedPointQueryParam);

    /**
     * 获取用户在线时长（状态）
     * @param userEventBuriedPointQueryParam
     * @return
     */
    UserOnlineTimeStatusVO getUserOnlineTimeStatus(UserEventBuriedPointQueryParam userEventBuriedPointQueryParam);

    /**
     * 获取用户在线时长明细（状态）
     * @param userEventBuriedPointQueryParam
     * @return
     */
    List<UserOnlineTimeStatusDetail> getUserOnlineTimeStatusDetailList(UserEventBuriedPointQueryParam userEventBuriedPointQueryParam);

    /**
     * 获取用户在线频次
     * @param userEventBuriedPointQueryParam
     * @return
     */
    UserOnlineFrequencyVO getUserOnlineFrequency(UserEventBuriedPointQueryParam userEventBuriedPointQueryParam);

    /**
     * 获取用户在线频次明细
     * @param userEventBuriedPointQueryParam
     * @return
     */
    List<UserOnlineFrequencyDetail> getUserOnlineFrequencyDetailList(UserEventBuriedPointQueryParam userEventBuriedPointQueryParam);

    /**
     * 获取用户在线频次
     * @param userEventBuriedPointQueryParam
     * @return
     */
    UserOnlineFrequencyStatusVO getUserOnlineFrequencyStatus(UserEventBuriedPointQueryParam userEventBuriedPointQueryParam);

    /**
     * 获取用户在线频次明细
     * @param userEventBuriedPointQueryParam
     * @return
     */
    List<UserOnlineFrequencyStatusDetail> getUserOnlineFrequencyDetailStatusList(UserEventBuriedPointQueryParam userEventBuriedPointQueryParam);

    /**
     * 添加用户登录埋点对象信息
     * @param customer
     * @param userEventBuriedPointParam
     * @return
     */
    SysUserEventBuriedPoint constructorUserEventBuriedPoint(Customer customer, UserEventBuriedPointParam userEventBuriedPointParam);

    /**
     * 获取支付转化结果
     * @param buriedPointQuery
     * @return
     */
    List<PayTransformVO> getPayTransform(BuriedPointQuery buriedPointQuery);

    /**
     * 获取用户量留存信息
     * @param date
     * @return
     */
    public List<RemainResultVO> getRemainResultList(String date);

    /**
     * 获取用户量留存信息
     * @param buriedPointQuery
     * @return
     */
    RemainVO getRemainInfo(BuriedPointQuery buriedPointQuery);

    /**
     * 获取动态数据列表
     * @param buriedPointQuery
     * @return
     */
    void getDynamicRemainInfo(HttpServletResponse response, BuriedPointQuery buriedPointQuery);

    /**
     * 获取支付统计结果
     * @param buriedPointQuery
     * @return
     */
    List<PayInfoVO> getPayInfo(BuriedPointQuery buriedPointQuery);

    /**
     * 获取训练统计结果
     * @param buriedPointQuery
     * @return
     */
    List<TrainInfoVO> getTrainInfo(BuriedPointQuery buriedPointQuery);

    /**
     * 查询埋点记录
     * @param buriedPointQuery
     * @return
     */
    List<SysBuriedPointVO> getSysBuriedPointList(BuriedPointQuery buriedPointQuery);

    /**
     * 查询埋点记录
     * @param buriedPointQuery
     * @return
     */
    List<SysBuriedPoint> getBuriedPointList(BuriedPointQuery buriedPointQuery);

    /**
     * 转化埋点明细
     * @param sysBuriedPointList
     * @return
     */
    List<SysBuriedPointVO> getSysBuriedPointVO(List<SysBuriedPoint> sysBuriedPointList);

    /**
     * 新增用户事件埋点统计结果
     */
    void insertUserEventBuriedPointResult(String date);

    /**
     * 新增埋点记录
     * 
     * @param sysBuriedPoint 埋点记录
     * @return 结果
     */
    public int insertSysBuriedPoint(SysBuriedPoint sysBuriedPoint);

    /**
     * 修改埋点记录
     * 
     * @param sysBuriedPoint 埋点记录
     * @return 结果
     */
    public int updateSysBuriedPoint(SysBuriedPoint sysBuriedPoint);

    /**
     * 批量删除埋点记录
     * 
     * @param ids 需要删除的埋点记录主键集合
     * @return 结果
     */
    public int deleteSysBuriedPointByIds(Long[] ids);

    /**
     * 删除埋点记录信息
     * 
     * @param id 埋点记录主键
     * @return 结果
     */
    public int deleteSysBuriedPointById(Long id);
}
